/* Base styles for all screen sizes */
.quiz-container {
    max-width: 90%;
    margin: 1.5rem auto;
    padding: 1.25rem;
    border: 4px solid green ;
    border-radius: 0.75rem;
    background-color: #F0F4F8;
    box-shadow: 0 0.5rem 1rem rgba(110, 107, 128, 0.1), 0 0.25rem 0.5rem rgba(61, 203, 224, 0.05);
    font-family: 'Roboto Condensed', 'Noto Sans', sans-serif;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.quiz-container:hover {
    transform: translateY(-0.125rem);
    box-shadow: 0 0.75rem 1.5rem rgba(0, 0, 0, 0.15), 0 0.375rem 0.75rem rgba(0, 0, 0, 0.1);
}

.group-action button{
    background-color: #00C4B4;
    padding: .5rem 1rem ;
    border-radius: 4px;
    -webkit-border-radius: 4px;
    -moz-border-radius: 4px;
    -ms-border-radius: 4px;
    -o-border-radius: 4px;
    margin-right: 1rem 2rem;
    min-width: 8rem;
    font-weight: 600;
    color: rgb(4, 30, 160);
}
.group-action{
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    align-items: center;

}

h1 {
    text-align: center;
    font-size: 2rem;
    color: #1A2A44;
    margin-bottom: 1.25rem;
    text-transform: uppercase;
    letter-spacing: 0.0625rem;
}

.group-turn {
    font-size: 1.2rem;
    color: #1A2A44;
    text-align: center;
    margin-bottom: 0.625rem;
    font-weight: bold;
    transition: color 0.3s ease;
}

#timer {
    font-size: 1.1rem;
    color: #FFFFFF;
    text-align: center;
    margin-bottom: 1rem;
    padding: 0.5rem;
    border-radius: 0.5rem;
    background: linear-gradient(135deg, #1E90FF, #5DADE2);
    box-shadow: 0 0.25rem 0.5rem rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

#timer.low-time {
    animation: pulseTimer 0.5s infinite ease-in-out;
}

@keyframes pulseTimer {
    0% { transform: scale(1); background: linear-gradient(135deg, #E63946, #FF6F61); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); background: linear-gradient(135deg, #E63946, #FF6F61); }
}

.question {
    font-size: 1.5rem;
    color: #1A2A44;
    margin-bottom: 1.25rem;
    line-height: 1.4;
    text-align: center;
    padding: 0.625rem;
    border-radius: 0.5rem;
    background-color: #FFFFFF;
    box-shadow: 0 0.25rem 0.5rem rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.question:hover {
    transform: translateY(-0.125rem);
}

.options {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-top: 1rem;
}

#optionButtons {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

#optionButtons button {
    padding: 0.625rem 1.25rem;
    font-size: 1rem;
    cursor: pointer;
    border: none;
    border-radius: 0.375rem;
    color: #FFFFFF;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2), 0 6px 20px rgba(0, 0, 0, 0.15);
    animation: fadeInUp 0.5s ease-out forwards;
    transition: transform 0.2s ease, background 0.3s ease, box-shadow 0.3s ease;
}

#optionButtons button:nth-child(1) {
    background: linear-gradient(135deg, #1E90FF, #5DADE2);
}

#optionButtons button:nth-child(2) {
    background: linear-gradient(135deg, #00C4B4, #26A69A);
}

#optionButtons button:nth-child(3) {
    background: linear-gradient(135deg, #E63946, #FF6F61);
}

#optionButtons button:nth-child(4) {
    background: linear-gradient(135deg, #F1C40F, #FFC107);
}

#optionButtons button:hover {
    transform: scale(1.05);
    background: linear-gradient(135deg, #FF6F61, #F1C40F);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.25), 0 8px 24px rgba(0, 0, 0, 0.2);
}

#optionButtons button:focus {
    outline: 2px solid #00C4B4;
    outline-offset: 2px;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.no-answer {
    padding: 0.625rem 1.25rem;
    font-size: 1rem;
    cursor: pointer;
    border: none;
    border-radius: 0.375rem;
    background: linear-gradient(135deg, #6C757D, #ADB5BD);
    color: #FFFFFF;
    box-shadow: 0 0.25rem 0.5rem rgba(0, 0, 0, 0.1);
    transition: transform 0.2s ease, background 0.3s ease, box-shadow 0.3s ease;
}

.no-answer:hover {
    transform: scale(1.05);
    background: linear-gradient(135deg, #FF6F61, #F1C40F);
    box-shadow: 0 0.375rem 0.75rem rgba(0, 0, 0, 0.15);
}

.no-answer:focus {
    outline: 2px solid #00C4B4;
    outline-offset: 2px;
}

.scoreboard {
    margin-top: 1.5rem;
    padding: 1rem;
    border-radius: 0.5rem;
    background-color: #FFFFFF;
    box-shadow: 0 0.25rem 0.5rem rgba(0, 0, 0, 0.1);
    animation: fadeIn 0.5s ease-in;
}

.scoreboard h3 {
    font-size: 1.5rem;
    color: #1A2A44;
    margin-bottom: 0.625rem;
    text-align: center;
}

.score-box {
    font-size: 1.25rem;
    color: #1A2A44;
}

.score-box p {
    margin: 0.3125rem 0;
    font-size: 1.2rem;
}

.score-box span {
    color: #00C4B4;
    font-weight: bold;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(0.625rem); }
    to { opacity: 1; transform: translateY(0); }
}

.music-button {
    display: flex;
    justify-content: center;
    margin-top: 1rem;
    align-items: center;
}

.music-button button {
    padding: 0.625rem 1.25rem;
    font-size: 1rem;
    cursor: pointer;
    border: none;
    border-radius: 0.375rem;
    background: linear-gradient(135deg, #FF6F61, #F1C40F);
    color: #FFFFFF;
    box-shadow: 0 0.25rem 0.5rem rgba(0, 0, 0, 0.1);
    transition: transform 0.2s ease, background 0.3s ease, box-shadow 0.3s ease;
}

.music-button button:hover {
    transform: scale(1.05);
    background: linear-gradient(135deg, #00C4B4, #26A69A);
    box-shadow: 0 0.375rem 0.75rem rgba(0, 0, 0, 0.15);
}

.music-button button:focus {
    outline: 2px solid #00C4B4;
    outline-offset: 2px;
}

#startButton {
    background: linear-gradient(135deg, #1E90FF, #5DADE2);
    margin: 1rem auto;
}

#startButton:hover {
    transform: scale(1.05);
    background: linear-gradient(135deg, #FF6F61, #F1C40F);
}

#startButton:focus {
    outline: 2px solid #00C4B4;
    outline-offset: 2px;
}

/* Mobile (≤600px) */
@media screen and (max-width: 600px) {
    .quiz-container {
        padding: 0.75rem;
        max-width: 95%;
        box-shadow: 0 0.25rem 0.5rem rgba(0, 0, 0, 0.1);
    }
.group-action{
    flex-direction: column;
    gap: 1rem;
}
    .quiz-container:hover {
        transform: none;
    }

    h1 {
        font-size: 1.5rem;
        margin-bottom: 0.75rem;
    }

    .group-turn {
        font-size: 1rem;
    }

    #timer {
        font-size: 0.9rem;
        padding: 0.375rem;
        box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.1);
    }

    .question {
        font-size: 1.1rem;
        margin-bottom: 0.75rem;
        padding: 0.375rem;
        box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.1);
    }

    #optionButtons {
        gap: 0.375rem;
    }

    #optionButtons button {
        padding: 0.375rem 0.75rem;
        font-size: 0.8rem;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2), 0 3px 10px rgba(0, 0, 0, 0.15);
    }

    #optionButtons button:hover {
        transform: scale(1.03);
        box-shadow: 0 3px 6px rgba(0, 0, 0, 0.25), 0 4px 12px rgba(0, 0, 0, 0.2);
    }

    .no-answer {
        padding: 0.375rem 0.75rem;
        font-size: 0.8rem;
        box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.1);
    }

    .no-answer:hover {
        transform: scale(1.03);
    }

    .scoreboard {
        padding: 0.625rem;
        box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.1);
    }

    .scoreboard h3 {
        font-size: 1.2rem;
    }

    .score-box {
        font-size: 1rem;
    }

    .score-box p {
        font-size: 0.95rem;
    }

    .music-button button {
        padding: 0.375rem 0.75rem;
        font-size: 0.8rem;
        box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.1);
    }

    .music-button button:hover {
        transform: scale(1.03);
    }

    #startButton {
        padding: 0.5rem 1rem;
        font-size: 0.9rem;
    }
}

/* Tablet (601px–1024px) */
@media screen and (min-width: 601px) and (max-width: 1024px) {
    .quiz-container {
        max-width: 85%;
        padding: 1rem;
        box-shadow: 0 0.375rem 0.75rem rgba(0, 0, 0, 0.1);
    }

    h1 {
        font-size: 1.7rem;
    }

    .group-turn {
        font-size: 1.1rem;
    }

    #timer {
        font-size: 1rem;
        padding: 0.5rem;
        box-shadow: 0 0.1875rem 0.375rem rgba(0, 0, 0, 0.1);
    }

    .question {
        font-size: 1.3rem;
        padding: 0.5rem;
        box-shadow: 0 0.1875rem 0.375rem rgba(0, 0, 0, 0.1);
    }

    #optionButtons {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
        gap: 0.625rem;
    }

    #optionButtons button {
        padding: 0.5rem 0.9375rem;
        font-size: 0.9rem;
        box-shadow: 0 3px 6px rgba(0, 0, 0, 0.2), 0 4px 12px rgba(0, 0, 0, 0.15);
    }

    #optionButtons button:hover {
        transform: scale(1.04);
        box-shadow: 0 4px 8px rgba(0, 0, 0, 0.25), 0 6px 16px rgba(0, 0, 0, 0.2);
    }

    .no-answer {
        padding: 0.5rem 0.9375rem;
        font-size: 0.9rem;
        box-shadow: 0 0.1875rem 0.375rem rgba(0, 0, 0, 0.1);
    }

    .no-answer:hover {
        transform: scale(1.04);
    }

    .scoreboard {
        padding: 0.75rem;
        box-shadow: 0 0.1875rem 0.375rem rgba(0, 0, 0, 0.1);
    }

    .scoreboard h3 {
        font-size: 1.3rem;
    }

    .score-box {
        font-size: 1.2rem;
    }

    .score-box p {
        font-size: 1.1rem;
    }

    .music-button button {
        padding: 0.5rem 0.9375rem;
        font-size: 0.9rem;
        box-shadow: 0 0.1875rem 0.375rem rgba(0, 0, 0, 0.1);
    }

    .music-button button:hover {
        transform: scale(1.04);
    }

    #startButton {
        padding: 0.625rem 1.25rem;
        font-size: 1rem;
    }
}

/* Desktop (>1024px) */
@media screen and (min-width: 1025px) {
    .quiz-container {
        max-width: 50rem;
        box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.1), 0 0.25rem 0.5rem rgba(0, 0, 0, 0.05);
    }

    h1 {
        font-size: 2rem;
    }

    .group-turn {
        font-size: 1.2rem;
    }

    #timer {
        font-size: 1.1rem;
        padding: 0.625rem;
        box-shadow: 0 0.25rem 0.5rem rgba(0, 0, 0, 0.1);
    }

    .question {
        font-size: 1.5rem;
        padding: 0.625rem;
        box-shadow: 0 0.25rem 0.5rem rgba(0, 0, 0, 0.1);
    }

    #optionButtons {
        flex-direction: row;
        justify-content: center;
        gap: 0.75rem;
        flex-direction: column;
    }

    #optionButtons button {
        padding: 0.625rem 1.25rem;
        font-size: 1rem;
        box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2), 0 6px 20px rgba(0, 0, 0, 0.15);
    }

    #optionButtons button:hover {
        transform: scale(1.05);
        box-shadow: 0 6px 12px rgba(0, 0, 0, 0.25), 0 8px 24px rgba(0, 0, 0, 0.2);
    }

    .no-answer {
        padding: 0.625rem 1.25rem;
        font-size: 1rem;
        box-shadow: 0 0.25rem 0.5rem rgba(0, 0, 0, 0.1);
    }

    .no-answer:hover {
        transform: scale(1.05);
    }

    .scoreboard {
        padding: 1rem;
        box-shadow: 0 0.25rem 0.5rem rgba(0, 0, 0, 0.1);
    }

    .scoreboard h3 {
        font-size: 1.5rem;
    }

    .score-box {
        font-size: 1.25rem;
        display: flex;
        justify-content: space-around;

    }

    .score-box p {
        font-size: 1.2rem;
    }

    .music-button button {
        padding: 0.625rem 1.25rem;
        font-size: 1rem;
        box-shadow: 0 0.25rem 0.5rem rgba(0, 0, 0, 0.1);
    }

    .music-button button:hover {
        transform: scale(1.05);
    }

    #startButton {
        padding: 0.75rem 1.5rem;
        font-size: 1.1rem;
    }
}